package com.lcz.service.impl;

import com.lcz.bean.Student;
import com.lcz.dao.StudentDao;
import com.lcz.dao.impl.StudentDaoImpl;
import com.lcz.service.StudentService;

import java.util.List;

public class StudentServiceImpl implements StudentService {

    private StudentDao studentDao= new StudentDaoImpl();

    @Override
    public Student findById(String stuid) {
        return studentDao.findById(stuid);
    }

    @Override
    public List<Student> getStudents(String stuname,String stuno,int sex,int pageIndex,int pageSize) {
        return studentDao.getStudents(stuname,stuno,sex,pageIndex,pageSize);
    }

    @Override
    public int total(String name, String stuno, int sex) {
        return studentDao.total(name,stuno,sex);
    }

    @Override
    public int insertStu(Student student) {
        return studentDao.insertStu(student);
    }

    @Override
    public int update(Student student) {
        return studentDao.update(student);
    }

    @Override
    public int delete(String stuid) {
        return studentDao.delete(stuid);
    }

    @Override
    public List isStuname() {
        return studentDao.isStuname();
    }
}
